package com.cjh.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cjh.pojo.Order;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author cjh
 * @since 2020-12-23
 */
@Repository
public interface OrderMapper extends BaseMapper<Order> {

    boolean insertOrder(Order order);

    List<Order> selectOrdersByUserId(Integer userId);

    List<Order> selectUntreatedOrders(Order order);

    Integer getOrderNumber(Integer userId);

    Integer getOrderCountByTypeName(String typeName);
}
